package com.lzc.tlmail.tlmailware.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.lzc.common.to.LockStockTastTO;
import com.lzc.common.to.mq.Orderto;
import com.lzc.common.utils.PageUtils;
import com.lzc.common.to.SkuWareVo;
import com.lzc.tlmail.tlmailware.Vo.LockWareOrdervo;
import com.lzc.tlmail.tlmailware.entity.WareSkuEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品库存
 *
 * @author lzc
 * @email 1029669636@gmail.com
 * @date 2020-07-26 19:19:12
 */
public interface WareSkuService extends IService<WareSkuEntity> {

    PageUtils queryPage(Map<String, Object> params);

    PageUtils queryPageByCondition(Map<String, Object> params);

    List<SkuWareVo> getSkusHasStock(List<Long> skuIds);

    Boolean lockWareOrder(LockWareOrdervo lockWareOrdervo);

    void lockOrderStock(LockStockTastTO lockStockTastTO);

    void unLockStock(Long skuId,Long wareId,Integer num);

    void closeOrder(Orderto orderto);
}

